package com.hrt.manage.product.service;

import java.lang.reflect.InvocationTargetException;
import java.util.List;

import org.hibernate.StaleObjectStateException;

import com.hrt.bean.ProductDetails;

public interface ProDetailsService {

	public void saveDetail(ProductDetails product);

	public List<ProductDetails> queryByPage(int pageIndex, int pageSize);

	public void deleteById(Long[] proIds);

	public ProductDetails getDetailById(Long deId);

	public boolean udateDetail(ProductDetails product) throws IllegalAccessException,StaleObjectStateException, InvocationTargetException;

	public Long totalCount(Long proId);

	public List<ProductDetails> queryByProId(Long proId, Integer pageIndex,
			Integer pageSize);

	public List<ProductDetails> queryByProId(Long id);

	
	public List<ProductDetails> queryProducts(String condtionStr);
	
	/**
	 * 查询所有
	 * */
	public List<ProductDetails> searchDelAll();

	/**
	 * 获取产品规格信息
	 * @param proId
	 * @param ruleId
	 * @return
	 */
	public ProductDetails getDetailByProIdAndRuleId(Long proId, Long ruleId);

	/**通过产品id查找产品规格*/
	public List<ProductDetails> getProDetailByProId(Long proId);
	
	/**
	 * 按id查询实体
	 * */
	public ProductDetails getById(Long id);

	

	/**
	 * 
	 * @param ruleId
	 * @return
	 */
	public Long getProInforDetailTotals(Long ruleId);
}
